home *** CD-ROM | disk | FTP | other *** search
/ Chaos CD Blue / Chaos_CD_Blue__[1999].iso / ftp_ccc_de / pub / gsm / gsm_log_commented < prev    next >
Text File  |  1998-05-17  |  1KB  |  41 lines

  1. Here's a protocol of how I talk to the GSM SIM card using stest from
  2. the sio package. It shows one round of computation of A3A8, and
  3. extraction of the IMSI.
  4.  
  5. The part including the # and anything after it is a comment. Don't
  6. type this in.
  7.  
  8. The first line is by me, the second comed from the card, the third
  9. from me etc.
  10.  
  11. $ ./stest -c /dev/ttyS0 # or whatever serial port you use
  12. Scan ATR        # search for right serial settings
  13. ... some data ...       # it tells you what serial parameters it has found
  14. r            # reset
  15. 3b 83 00 12 10 96    # ATR
  16. t a0 a4 00 00 02    # SelectFile
  17. a4            # ok 
  18. t 7f 20            # gsm_dir
  19. 9f 19            # ok, 0x19 bytes result available
  20. t a0 c0 00 00 19    # get response
  21. c0 00 00 00 00 7f 20 02 00 00 11 00 01 0c 1b 00 12 04 00 83 8a 03 8a 00 03 83 90 00 # boring data
  22. t a0 20 00 01 08    # PIN verification
  23. 20            # ok
  24. t 35 35 35 35 ff ff ff ff # PIN (5555 in this case)
  25. 90 00            # ok
  26. t a0 88 00 00 10    # execute A3A8, we have 0x10 bytes of data
  27. 88            # ok
  28. t 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 # this is my challenge RAND
  29. 9f 0c            # 0x0c bytes response
  30. t a0 c0 00 00 0c    # get response 
  31. c0 88 72 d1 02 18 fd 5f 1b 44 a4 60 00 90 00 # one byte command, 4 bytes SRES, 8 bytes Kc, two bytes status
  32. t a0 a4 00 00 02    # select file
  33. a4            # ok
  34. 6f 07            # IMSI
  35. t a0 b0 00 00 09    # read data
  36. 9f 09            # ok, 9 bytes response
  37. t a0 c0 00 00 09    # get data
  38. c0 08 29 03 29 83 40 04 32 45 90 00 # one byte command, 9 bytes IMSI, 2 bytes status
  39.  
  40. Andreas
  41.